#!/bin/sh

rootfs_open -t

restorefile(){
    if [ -e "$1.old" ]; then
        cp "${1}.old" "${1}"
    fi
    rm -f "$1.old"
}

#restorefile "/usr/palm/frameworks/mojo2/submissions/99/resources/zh/datetime_table.json"
#restorefile "/usr/palm/frameworks/mojo2/submissions/99/resources/zh/cn/datetime_table.json"
restorefile "/usr/lib/luna/customization/locale.txt"

##
##  workaround
##

for i in `ipkg files com.palm.veer.languagepack.zh-cn | grep 0000644`; do
    rm -f "${i/0000644}" "$i"
done